<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title></title>
    <meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/application.css"></c:url>">
    <link rel="stylesheet" type="text/css" href="<c:url value="/css/form.css"></c:url>">
    <link rel="stylesheet" type="text/css" href="<c:url value="/css/shop_main.css" />">
    
    <script type="text/javascript">

        function logout() 
        {
			if(confirm("您真的要离开当当网吗?")) 
			{
				location.href="<c:url value="/security?act=logout"/>";
			}
	    }
         
	     function validate_required(field,alerttxt)
         {
              with (field)
              {
                  if (value==null||value=="")
                     {
                      alert(alerttxt);return false}
                      else {return true}
               }
         }    
         
         function validate_form(thisform)
         {
              with (thisform)
              {
                   if (validate_required(customerid,"ID不能为空!")==false)
                      {receiver.focus();return false}
                   if (validate_required(customerpwd,"密码不能为空!")==false)
                      {receiver_add.focus();return false}
                   if (validate_required(customername,"用户名不能为空!")==false)
                      {receive_mode.focus();return false}
                 
              }
         }
    </script>
 
  </head>
  
  <body>
    <DIV class=head_container>
       <DIV class=head_welcome  >
			<SPAN class=head_toutext id=nickname > 
				您好,${loginedCustomer.customerName} 
    			[<SPAN onclick="logout();" style="cursor:hand;color:green">退出系统</SPAN>]
			</SPAN>
			<DIV class=little_navi>
				<FORM id=bootpagetopSearch name=bootpagetopSearch
					action="" method=get>
					<DIV class=little_n> 
						| <A href="<c:url value="/myDD?act=showMyDD" />" target=mydangdang name=mydangdang>我的当当</A> 
					</DIV>
				</FORM>
			</DIV>
			<DIV class="cart gray4012">
				<A href="#">购物车</A>
			</DIV>
			<P class=welcome_p id=nickname></P>
    	</DIV>
		<DIV class=head_head_list >
			<DIV class=head_head_list_left>
				<SPAN class=head_logo> 
					<A href="#" name=backtobook>
						<IMG src="<c:url value="/pics/front/book_logo.gif" />"> 
					</A> 
				</SPAN>
			</DIV>
			<DIV class=head_head_list_right>
				<DIV class=head_lianjie>
					<IMG class=head_lianjie1 src="<c:url value="/pics/front/bg_book.gif" />">
					<A href="#" name=backtobook>
					   <IMG src="<c:url value="/pics/front/book_dangdang.gif" />" border=0>
				    </A>
				</DIV>
			</DIV>
		</DIV>
	    	

    <form action="<c:url value="/customer"/>" method="post" onsubmit="return validate_form(this)">
        <input type="hidden" name="act" value="register" />
        <div style=" margin-right:500px; margin-left:100px; margin-top:30px;margin-bottom:480px;border:solid #CCCCCC;">
            <ul>
                <li>
                    <span class="lableFont">会员账号:</span>
	                <input type="text" class="text" name="customerid" size="20" value="${param['customerid']}"/>
                </li>
                <li>
                    <span class="lableFont">登陆密码:</span>
	                <input type="text" class="text" name="customerpwd" size="20" value="${param['customerpwd']}"/>
                </li>
                <li>
                    <span class="lableFont">会员姓名:</span>
	                <input type="text" class="text" name="customername" size="20" value="${param['customername']}"/>
                </li>
                <li>
                
                </li>
            </ul>

        <div class="submitDiv">
	        <input type="submit" value="提交注册"/>
	        <input type="reset" value="取消重写"/>
	      </div>
	  </div>
    </form>

    
    </DIV>
    
    
  </body>
</html>
